package net.openvision.music.model.event;

import net.openvision.music.model.Length;

public abstract class AbstractScoreEvent implements ScoreEvent {
	
	public final static int ALL_STAVES = -1;
	
	protected int staffNr;
	protected int barNr;
	protected Length barPosition;
	
	public AbstractScoreEvent(int staffNr, int barNr, Length barPosition) {
		this.barNr = barNr;
		this.barPosition = barPosition;
		this.staffNr = staffNr;
	}
	
	public AbstractScoreEvent(int barNr) {
		this(ALL_STAVES, barNr, new Length(0, 1));
	}
	
	@Override
	public int getBarNr() {
		return barNr;
	}

	@Override
	public Length getBarPosition() {
		return barPosition;
	}
	
	@Override
	public int getStaffNr() {
		return staffNr;
	}
	
	

}
